package com.yl.login.viewmodel

import com.yl.common.base.BaseViewModel
import com.yl.common.network.RespStateData
import com.yl.login.bean.LoginBean
import com.yl.login.repo.LoginRepo

/**
 * Created by stew on 8/5/22.
 */
class LoginViewModel(private var repo: LoginRepo): BaseViewModel() {
    var loginData =  RespStateData<LoginBean>()

    fun login(username: String, password: String) {
        launch(
            block = {
                repo.login(username, password,loginData)
            }
        )
    }
}